package de.tabuma.pm.externalproject.logik;

import de.tabuma.pm.externalproject.entity.*;
import de.tabuma.pm.logik.*;

import java.util.*;
import java.util.logging.*;

/**
  * @author $Author: $
  * @version $Revision: $
  * @since $Date: $
 */
public class LoginUserParameterFacade {

    private static final Logger log = Logger.getLogger(LoginUserParameterFacade.class.getName());

    public static int create(LoginUserParameter epv, String user) {
        return (int) PMF.doCreate(epv, user);
    }

    public static LoginUserParameter get(int ID) {
        return PMF.get(ID, new LoginUserParameter());
    }

    public static void update(LoginUserParameter epv, String user) {
        PMF.doUpdate(epv, user);
    }

    public static void remove(int epvID, String user) {
        LoginUserParameter eplp = LoginUserParameterFacade.get(epvID);
        PMF.doRemove(eplp, user);
    }

    public static List<LoginUserParameter> getList(int externalprojectId) {
        String keys[] = new String[1];
        keys[0] = "externalprojectId";
        String values[] = new String[1];
        values[0] = ""+externalprojectId;
        return PMF.get(keys, values, new LoginUserParameter());
    }
}
